#include<stdio.h>
#include<unistd.h>
#include<string.h>

#define MAX 101
int main()
{
   char bar[MAX+1];
   char *arr="|/-\\";
   memset(bar,0,MAX+1);
   int count =0;
   
   while(count<MAX)
   {
      bar[count]='=';
    bar[count+1]='>';
    printf("[%-100s][%d%%][%c]\r",bar,count,arr[count%4]);
      fflush(stdout);
      usleep(100000);
      count++;

   }
   printf("\n");
  return 0;
}
